#ifndef									__UDPSOCKET_H__
#define									__UDPSOCKET_H__

#include								<boost/asio.hpp>
#include								"ASocket.h"

class									UdpSocket : public ASocket
{
public:
	UdpSocket(boost::asio::io_service &);
	virtual ~UdpSocket();

private:
	boost::asio::ip::udp::socket		_socket;

private:
	virtual void						_startRead();
	boost::asio::ip::udp::endpoint		_sender;

public:
	virtual void						start();
	virtual	void						close();
	boost::asio::ip::udp::socket		&getSocket();
	virtual std::string					getIp() const;
	void                                                    _receive(const boost::system::error_code &, size_t);

};

#endif // ! __UDPSOCKET_H__
